package com.test.rmi;

import javax.naming.Context;
import javax.naming.Name;
import javax.naming.spi.ObjectFactory;
import java.util.Hashtable;

/**
 * @author: yushaopeng
 * @date: 2021/12/11
 **/
public class EvilObj implements ObjectFactory {
    static {
        System.out.println("I am in");
    }

    @Override
    public Object getObjectInstance(Object obj, Name name, Context nameCtx, Hashtable<?, ?> environment) throws Exception {
        System.out.println("I have been called");
        return "";
    }
}
